<?php 
namespace App;

use Illuminate\Database\Eloquent\Model;

class Order extends Model {

	 protected $guarded = ['id'];
         public $updated_at = false;
         protected $table='orders';
       public function items()
    {
        return $this->hasMany('App\Item','orderId');
    }
    
    public function picker()
    {
        return $this->belongsTo('App\User','pickerId');
    }
     public function rider()
    {
        return $this->belongsTo('App\User','riderId');
    }
    
//    public function picker()
//    {
//         return $this->hasOne('App\User');
//    }
//      public function rider()
//    {
//         return $this->hasOne('App\User','id');
//    }
    

}
